package summer_vacation.zengguangchuan;

import java.util.Scanner;

/**作业39
 * Created by lenovo0 on 2015/9/1.
 */
public class Assignment_16 {
    public static void main(String[] args) {
        System.out.print("请输入一个数：");
        Scanner input = new Scanner(System.in);
        double n=input.nextInt();
        double j=0;
        double sum=0;
        for(double i=1;i<=n;i++){
            j=j+i;
            sum=sum+1/j;
        }
        System.out.println(sum);
    }
}
